package com.example.service;

import com.example.entity.Goods;
import org.springframework.stereotype.Service;

import java.util.List;


public interface GoodsService {
    Goods getGoodsById(Integer gid);
    //遍历
    List<Goods> getAllGoods();
    //增加
    boolean addGoods(Goods goods);
    //修改
    boolean updateGoods(Goods goods);
    //删除
    boolean deleteGoods(Integer gid);
//查找总页数
    int totalPage(int PageNum);
    //查找页面商品
    List<Goods> findGoodsByPage(int page,int pagNum);
    List<Goods> getGoodsByAuthor(String name);
    List<Goods> searchGoodsByType(String type,String author);
}
